import 'package:flutter/material.dart';
import 'package:flutter/widgets.dart';

class buildButtonColumn extends StatelessWidget {


  final String label; //定义一个常量，用于保存跳转进来获取到的参数
  final IconData icon;

  buildButtonColumn(this.icon,this.label);//构造函数，获取参数


  @override
  Widget build(BuildContext context) {
    // TODO: implement build
    Color color = Colors.blue[500];
    return new Column(
      mainAxisSize: MainAxisSize.min,
      mainAxisAlignment: MainAxisAlignment.center,
      children: [
        new Icon(icon, color: color),
        new Container(
          margin: const EdgeInsets.only(top: 8.0),
          child: new Text(
            label,
            style: new TextStyle(
              fontSize: 12.0,
              fontWeight: FontWeight.w400,
              color: color,
            ),
          ),
        ),
      ],
    );
  }
}
